<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>社区</title>
    <script src="/static/js/jquery-1.11.3.min.js" type="text/javascript"></script>
    <!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
    <!-- 可选的 Bootstrap 主题文件（一般不用引入） -->
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap-theme.min.css" integrity="sha384-rHyoN1iRsVXV4nD0JutlnGaslCJuC7uwjduW9SVrLvRYooPp2bWYgmgJQIXwl/Sp" crossorigin="anonymous">
    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
    <link rel="stylesheet" href="/static/css/index.css"/>
</head>
<body>
<header></header>
<nav th:insert="~{nav.html :: navigation}"></nav>
<main>
    <div class="container-fluid main">
        <div class="row">
            <div class="col-lg-9 col-lg-12 col-sm-12">
                <h2><span class="glyphicon glyphicon-list" aria-hidden="true"></span>&nbsp;发现</h2>
                <hr>
                <div class="context">
                    <div class="media" th:each="que:${questions.questionDTOS}">
                        <div class="media-left">
                            <a href="#">
                                <img class="media-object img-rounded" th:src="${que.user.avatarUrl}">
                            </a>
                        </div>
                        <div class="media-body">
                            <h4 class="media-heading" th:text="${que.title}"></h4>
                            <span th:text="${que.description}"></span> <br>
                            <span class="text-desc">2个回复*31次浏览*<span th:text="${#dates.format(que.gmtCreate,'yyyy-MM-dd HH:mm')}"></span></span>
                        </div>
                    </div>
                    <nav aria-label="Page navigation" th:align="center">
                        <ul class="pagination">
                            <li th:if="${questions.showPrevious}">
                                <a th:href="@{/(currentPage=(${questions.currentPage}-1))}" aria-label="Previous">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                            </li>
                            <li th:each="page:${questions.page}" th:class="${questions.currentPage==page}?'active':''">
                                <a th:href="@{/(currentPage=${page})}" th:text="${page}" >

                                </a>
                            </li>
                            <li th:if="${questions.showNext}">
                                <a th:href="@{/(currentPage=(${questions.currentPage}+1))}" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                            </li>
                        </ul>
                    </nav>
                </div>

            </div>
            <!--            tab键一键生成-->
            <div class="col-lg-3 col-md-12 col-sm-12">
                <h3>热门话题</h3>
            </div>
        </div>
    </div>
</main>
</body>
</html>